home *** CD-ROM | disk | FTP | other *** search
/ IRIX 6.5 Applications 1999 May / SGI IRIX 6.5 Applications 1999 May.iso / dist / insight.idb / usr / share / Insight / xhelp / samples / exampleApp / exampleAppXmHelp.sgm.z / exampleAppXmHelp.sgm
Text File  |  1998-05-04  |  5KB  |  183 lines

  1.  
  2. <dochelp>
  3.  
  4. <HelpTopic HelpID="overview">
  5. <Helplabel>Example Motif Application Using SGIHelp</Helplabel>
  6. <Description>
  7. <para>
  8. This application is intended to show the developer how
  9. the <glossterm>SGIHelp</glossterm> system can work for you. 
  10. It displays (in the included
  11. sample code, exampleAppXm.c) usage of various widgets, a sample 
  12. help menu, full-context-sensitivity, and calls to 
  13. the <glossterm>SGIHelp</glossterm> server process via the API.
  14. </para>
  15.  
  16. <Figure ID="figure_01">
  17.     <title>exampleAppXm Main Window</title>
  18.     <Graphic fileref="mainwnd.gif" format="GIF"></Graphic>
  19. </Figure>
  20.  
  21. <para>
  22. The application itself is very simple, composed of
  23. a <Link Linkend="ID002">File menu,</Link> 
  24. a <Link Linkend="ID003">Help menu,</Link> 
  25. a <Link Linkend="ID005">Pushbutton,</Link> 
  26. and a <Link Linkend="ID004">Label</Link>.
  27. The user can choose items from the 
  28. <Link Linkend="ID003">Help menu</Link> to
  29. contact the <glossterm>SGIHelp</glossterm> server process to 
  30. cause different help cards to be rendered.
  31. </para>
  32. <para>To quit the application, use the "Exit" command
  33. found under the <Link Linkend="ID002">File menu</Link>.
  34. </para>
  35. </Description>
  36. </HelpTopic>
  37.  
  38.  
  39. <HelpTopic HelpID="file_menu">
  40. <Helplabel><Anchor Id="ID002">The File Menu</Helplabel>
  41. <Description>
  42. <para>The following items (and their functions) are part of 
  43. the File menu:</para>
  44. <VariableList>
  45. <VarListEntry>
  46. <term>Exit</term>
  47. <ListItem><para>Used to quit the exampleAppXm application.</para></listitem>
  48. </VarListEntry>
  49. </VariableList>
  50. </Description>
  51. </HelpTopic>
  52.  
  53.  
  54. <HelpTopic HelpID="help_menu">
  55. <Helplabel><Anchor Id="ID003">The Help Menu</Helplabel>
  56. <Description>
  57. <para>The following items (and their functions) are part of 
  58. the Help menu:</para>
  59. <VariableList>
  60. <VarListEntry>
  61. <term>Click for Help</term>
  62. <ListItem><para>Used to put the application in context sensitive mode.
  63. Will cause the cursor to turn into a "?" at which point the user can
  64. click on any entry in the application's window to obtain help.</para></listitem>
  65. </VarListEntry>
  66. <VarListEntry>
  67. <term>Overview</term>
  68. <ListItem><para>Used to display a help overview card for the current 
  69. window.</para></listitem>
  70. </VarListEntry>
  71. <VarListEntry>
  72. <term>Index</term>
  73. <ListItem><para>Used to display from SGIHelp an Index of help topics for 
  74. the given application.</para></listitem>
  75. </VarListEntry>
  76. <VarListEntry>
  77. <term>Keys & Shortcuts</term>
  78. <ListItem><para>Used to display a help card that describes any special
  79. key combinations this application uses.</para></listitem>
  80. </VarListEntry>
  81. <VarListEntry>
  82. <term>Product Info</term>
  83. <ListItem><para>Pops up a dialog that displays to the user any version or
  84. copyright information for this application.</para></listitem>
  85. </VarListEntry>
  86. </VariableList>
  87. <para>To access any menu items, click on the menu item
  88. that is a part of the menubar. When the menu pops-up,
  89. highlight the desired item, and release the mouse button.
  90. </para>
  91. </Description>
  92. </HelpTopic>
  93.  
  94.  
  95. <HelpTopic HelpID="help_label">
  96. <Helplabel><Anchor Id="ID004">A Label</Helplabel>
  97. <Description>
  98. <para>You have clicked on a Label. It simply displays information
  99. to the user and serves no other useful pourpose.</para>
  100. <tip><para>Basically, a label is useless. For information only.</para></tip>
  101. </Description>
  102. </HelpTopic>
  103.  
  104.  
  105. <HelpTopic HelpID="help_button">
  106. <Helplabel><Anchor Id="ID005">A Pushbutton</Helplabel>
  107. <Description>
  108. <para>You have clicked on a Pushbutton. A pushbutton, when
  109. clicked, will activate some type of command within the application.</para> 
  110. </Description>
  111. </HelpTopic>
  112.  
  113.  
  114. <HelpTopic HelpID="keys">
  115. <Helplabel><Anchor Id="ID006">Keys and Shortcuts</Helplabel>
  116. <Description>
  117. <para>This card displays all known keys and shortcuts for this
  118. application.</para> 
  119. <warning><para>This application has no shortcuts.</para></warning>
  120. </Description>
  121. </HelpTopic>
  122.  
  123.  
  124. <HelpTopic HelpID="help_task">
  125. <Helplabel><Anchor Id="ID007">A Sample Help Task</Helplabel>
  126. <Description>
  127. <para>
  128. When creating your application and help text, you may wish
  129. to highlight certain common tasks. This help card was
  130. displayed from either a menu item or a pushbutton.
  131. </para>
  132. <para>
  133. To perform such an operation within your code, the
  134. associated callback that contacts the <glossterm>SGIHelp</glossterm> server 
  135. can be constructed as shown below.</para>
  136. <Example>
  137. <Title>Sample Help Task Callback</Title>
  138.  
  139. <para>
  140. The following is a listing derived from a "C" program:
  141. <ProgramListing>
  142.     /* create menu items, pushbuttons, etc. */
  143.  
  144.     void taskCB()
  145.     {
  146.  
  147.     /*
  148.      * For the task found in the help menu,
  149.      * we'll use a specific key/book 
  150.      * combination.
  151.      */
  152.         SGIHelpMsg("key", "myBook", NULL);
  153.     }
  154. </ProgramListing>
  155. </para>
  156. </Example>
  157. <para>It's relatively simple process to integrate help
  158. into your application. In fact, the <glossterm>SGIHelp</glossterm>
  159. process only requires <emphasis>two</emphasis> function calls.
  160. </para>
  161. </Description>
  162. </HelpTopic>
  163.  
  164.  
  165. <Glossary>
  166. <Title>Glossary</Title>
  167.  
  168. <GlossEntry>
  169. <GlossTerm>SGIHelp</GlossTerm>
  170. <GlossDef>
  171. <para>This is Silicon Graphics, Inc. version of a "Xhelp" compatible
  172. server. Through the use of an available API, and a help text
  173. compiler, books can be constructed that can be used to render
  174. help information for the given application.</para>
  175. </GlossDef>
  176. </GlossEntry>
  177.  
  178. </Glossary>
  179.  
  180.  
  181. </dochelp>
  182.  
  183.